<!DOCTYPE html>
<html lang="en-US">
    <head>
        <title>B::Generate - Create your own op trees. - metacpan.org</title>
        <link rel="preload" as="fetch" href="https://metacpan.org/account/login_status" crossorigin="anonymous" />
        <link href="https://metacpan.org/_assets/b8ccceeed47a0652049703d99326a9cea4933443.css" rel="stylesheet" type="text/css">
        <script src="https://metacpan.org/_assets/6bfedafe2d7caa915b7d84f61b45936818e3242e.js" type="text/javascript" defer></script>
        <link rel="alternate" type="application/rss+xml" title="Recent CPAN Uploads of B-Generate - MetaCPAN" href="https://metacpan.org/dist/B-Generate/releases.rss" />
        <link rel="canonical" href="./B::Generate.html" />
        <meta name="description" content="Create your own op trees." />
        <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=5">
        <link rel="shortcut icon" href="https://metacpan.org/static/icons/favicon.ico">
        <link rel="apple-touch-icon" sizes="152x152" href="https://metacpan.org/static/icons/apple-touch-icon.png">
        <link rel="search" href="https://metacpan.org/static/opensearch.xml" type="application/opensearchdescription+xml" title="MetaCPAN">
        <script>
          (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
          (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
          m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
          })(window,document,'script','//www.google-analytics.com/analytics.js','ga');

          (function(skey, ga_id){
            ga('create', ga_id, {
              siteSpeedSampleRate : 100,
              storage             : 'none',
              clientId            : localStorage.getItem(skey)
            });
            ga(function(tracker) {
              localStorage.setItem(skey, tracker.get('clientId'));
            });
            ga('send', 'pageview');
          })('ga:clientId', 'UA-27829474-1');
        </script>
<meta name="twitter:card"        content="summary" />
<meta name="twitter:url"         content="https://metacpan.org/pod/B::Generate" />
<meta name="twitter:title"       content="B::Generate" />
<meta name="twitter:description" content="Create your own op trees." />
<meta name="twitter:site"        content="metacpan" />
    </head>
    <body>
        <nav class="navbar navbar-default" role="navigation">
            <div class="header-logo-large hidden-xs">
              <a href="https://metacpan.org/" tabindex="0">
                <svg class="logo" aria-label="MetaCPAN">
                  <use class="logo" href="/static/images/metacpan-logo.svg#logo" />
                </svg>
              </a>
            </div>
            <div class="header-logo-icon visible-xs">
              <a href="https://metacpan.org/">
                <svg class="logo" aria-label="MetaCPAN">
                  <use class="logo" href="/static/images/metacpan-logo.svg#dots" />
                </svg>
              </a>
            </div>
            <ul class="nav navbar-nav menu-items hidden-xs hidden-sm">
              <li><a href="https://metacpan.org/about">About</a></li>
              <li><a href="https://metacpan.org/about/sponsors">Sponsor</a></li>
              <li><a href="https://grep.metacpan.org/">grep::cpan</a></li>
              <li><a href="https://metacpan.org/recent">Recent</a></li>
              <li><a href="https://metacpan.org/about/faq">FAQ</a></li>
              <li><a href="https://metacpan.org/tools">Tools</a></li>
              <li><a href="https://fastapi.metacpan.org/">API</a></li>
            </ul>
            <ul class="nav navbar-nav navbar-right">
                <button type="button" class="searchbar-btn visible-xs visible-sm">
                    <i class="fa fa-search button-fa-icon"></i>
                </button>
                <form action="https://metacpan.org/search" class="searchbar-form visible-md visible-lg search-form form-horizontal">
                   <input type="hidden" name="size" id="metacpan_search-size" value="20">
                  <div class="form-group">
                      <div class="search-group">
                        <i class="fa fa-search"></i>
                        <input type="text" name="q" placeholder="Search the CPAN" size="41" autocorrect="off" autocapitalize="off" spellcheck="false" id="metacpan_search-input" class="form-control" value="">
                      </div>
                  </div>
                </form>
                    <li class="icon-slidepanel visible-xs visible-sm">
                      <button data-toggle="slidepanel" data-target=".slidepanel">
                        <span class="button-fa-icon">
                          <i class="fa fa-bars slidepanel-open"></i>
                          <i class="fa fa-times slidepanel-close"></i>
                        </span>
                      </button>
                    </li>
                <form action="https://metacpan.org/account/logout" method="POST" id="metacpan-logout"></form>
                <li class="dropdown logged_in" style="display: none;">
                    <button type="button" class="dropdown-toggle" data-toggle="dropdown">
                      <i class="fa fa-user button-fa-icon logged-in-icon" aria-hidden="true"></i>
                      <i class="fas fa-chevron-down"></i>
                    </button>
                    <ul class="dropdown-menu">
                        <li><a href="https://metacpan.org/account/identities">Identities</a></li>
                        <li><a href="https://metacpan.org/account/profile">Profile</a></li>
                        <li><a href="https://metacpan.org/account/favorite/list">Favorites</a></li>
                        <li>
                            <a href="./B::Generate.html#" type="button" onclick="$('#metacpan-logout').submit(); return false">
                              Logout
                            </a>
                        </li>
                    </ul>
                </li>
                <li class="dropdown logged_out" style="display: none;">
                    <button type="button" class="dropdown-toggle" data-toggle="dropdown">
                      <i class="fa fa-user button-fa-icon" aria-hidden="true"></i>
                      <i class="fas fa-chevron-down"></i>
                    </button>
                    <ul class="dropdown-menu">
                        <li>
                            <a href="https://metacpan.org/login/github">
                                <i class="fab fa-github fa-fw"></i>
                                GitHub
                            </a>
                        </li>
                        <li>
                            <a href="https://metacpan.org/login/twitter">
                                <i class="fab fa-twitter fa-fw"></i>
                                Twitter
                            </a>
                        </li>
                        <li>
                            <a href="https://metacpan.org/login/google">
                                <i class="fab fa-google fa-fw"></i>
                                Google
                            </a>
                        </li>
                    </ul>
                </li>
                <li class="dropdown logged_placeholder">
                    <button>
                      <i class="fa fa-user button-fa-icon" aria-hidden="true"></i>
                    </button>
                </li>
            </ul>
        </nav>
        <div class="page-content ">
          <!--
          <div class="top-notify-banner">
            <i class="fas fa-info-circle"></i>
          </div>
          -->
          <nav class="sidebar">
            <div class="slidepanel">
              <ul class="nav-list ">
    <li class="nav-header no-margin-top">
      <div class="ttip" data-toggle="tooltip" data-placement="bottom" title="The date that this version of B-Generate was released.">
      <span class="relatize">20 Dec 2017 15:55:16 UTC</span>
    </li>
  <li>
    Distribution: <a href="https://metacpan.org/dist/B-Generate">B-Generate</a>
  </li>
  <li>
    Module version: 1.56
  </li>
  <li>
    <a data-keyboard-shortcut="g s" href="https://metacpan.org/dist/B-Generate/source/lib/B/Generate.pm">Source</a>
    (<a href="https://metacpan.org/dist/B-Generate/source/lib/B/Generate.pm?raw=1">raw</a>)
  </li>
  <li>
    <a data-keyboard-shortcut="g b" href="https://metacpan.org/dist/B-Generate/source/lib/B">Browse</a>
    (<a href="https://metacpan.org/dist/B-Generate/source/lib/B?raw=1">raw</a>)
  </li>
    <li>
      <a data-keyboard-shortcut="g c" href="https://metacpan.org/dist/B-Generate/changes">Changes</a>
    </li>
    <li>
      <a class="nopopup" href="https://metacpan.org/dist/B-Generate/contribute">How to Contribute</a>
    </li>
    <li>
        <a rel="noopener nofollow" data-keyboard-shortcut="g r" href="https://github.com/rurban/b-generate">Repository</a>
    </li>
    <li>
      <a rel="noopener nofollow" data-keyboard-shortcut="g i" href="https://rt.cpan.org/Public/Dist/Display.html?Name=B-Generate">Issues</a>
      (0)
    </li>
    <li>
      <a rel="noopener nofollow" href="http://matrix.cpantesters.org/?dist=B-Generate+1.56" title="Matrix">Testers</a>
        <span title="(pass / fail / na)">(<a rel="noopener nofollow" href="https://www.cpantesters.org/distro/B/B-Generate.html?oncpan=1&amp;distmat=1&amp;version=1.56&amp;grade=2" style="color: #090">3474</a> / <a rel="noopener nofollow" href="https://www.cpantesters.org/distro/B/B-Generate.html?oncpan=1&amp;distmat=1&amp;version=1.56&amp;grade=3" style="color: #900">1</a> / <a rel="noopener nofollow" href="https://www.cpantesters.org/distro/B/B-Generate.html?oncpan=1&amp;distmat=1&amp;version=1.56&amp;grade=4">0</a>)</span>
    </li>
    <li>
      <a rel="noopener nofollow" href="http://cpants.cpanauthors.org/release/RURBAN/B-Generate-1.56">Kwalitee</a>
    </li>
    <li>
      <div class="ttip" data-toggle="tooltip" data-placement="bottom" title="The # people with an indexing permission on B-Generate who have released something to CPAN in the last 2 years (i.e. the # people likely able to release critical fixes in a timely manner)">
      Bus factor: 2
      </div>
    </li>
    <li>
      <a rel="noopener nofollow" href="http://cpancover.com/latest/B-Generate-1.56/index.html">23.68% Coverage </a>
    </li>
    <li>
      License: unknown
    </li>
    <li class="nav-header">Activity</li>
    <li>
<div class="activity-graph">
    <img src="https://metacpan.org/dist/B-Generate/activity.svg?res=month" />
    <div class="comment">24 month</div>
</div>
    </li>
    <li class="nav-header">Tools</li>
    <li>
      <a itemprop="downloadUrl" href="https://cpan.metacpan.org/authors/id/R/RU/RURBAN/B-Generate-1.56.tar.gz">
      Download (<span itemprop="fileSize">37.6KB</span>)</a>
    </li>
    <li>
      <a href="https://explorer.metacpan.org/?url=%2Fmodule%2FRURBAN%2FB-Generate-1.56%2Flib%2FB%2FGenerate.pm">
        MetaCPAN Explorer
      </a>
    </li>
    <li>
      <a href="https://metacpan.org/dist/B-Generate/permissions">
        Permissions
      </a>
    </li>
    <li>
      <a href="https://metacpan.org/dist/B-Generate/releases.rss">
        Subscribe to distribution
      </a>
    </li>
    <li>
      <button class="btn btn-link" data-toggle="modal" data-target="#metacpan_install-instructions-dialog">
        Install Instructions
      </button>
    </li>
    <li>
      <form action="https://metacpan.org/search">
        <input type="hidden" name="q" value="dist:B-Generate">
        <input type="search" name="q" placeholder="Search distribution" class="form-control tool-bar-form">
        <input type="submit" style="display: none">
      </form>
    </li>
    <li>
      <form action="https://grep.metacpan.org/search">
        <input type="hidden" name="qd" value="B-Generate">
        <input type="hidden" name="source" value="metacpan">
        <input type="search" name="q" placeholder="grep distribution" class="form-control tool-bar-form">
        <input type="submit" style="display: none">
     </form>
    </li>
    <li class="version-jump">
<select onchange="document.location.href=&#39;/release/&#39;+this.value+&#39;/view/lib/B/Generate.pm&#39;" class="form-control tool-bar-form">
  <option disabled selected>Jump to version</option>
<option
  disabled
  value="RURBAN/B-Generate-1.56"
>1.56
  (RURBAN on 2017-12-20)</option>
<option
  
  value="RURBAN/B-Generate-1.55"
>1.55
  (RURBAN on 2017-02-23)</option>
<option
  
  value="RURBAN/B-Generate-1.54"
>1.54
  (RURBAN on 2016-05-26)</option>
<option
  
  value="RURBAN/B-Generate-1.53"
>1.53
  (RURBAN on 2015-05-04)</option>
<option
  
  value="RURBAN/B-Generate-1.52"
>1.52
  (RURBAN on 2015-05-03)</option>
<option
  
  value="RURBAN/B-Generate-1.51"
>1.51
  (RURBAN on 2015-05-02)</option>
<option
  
  value="RURBAN/B-Generate-1.50"
>1.50
  (RURBAN on 2014-12-24)</option>
<option
  
  value="RURBAN/B-Generate-1.49"
>1.49
  (RURBAN on 2014-08-08)</option>
<option
  
  value="RURBAN/B-Generate-1.48"
>1.48
  (RURBAN on 2013-09-30)</option>
<option
  
  value="RURBAN/B-Generate-1.43"
>1.43
  (RURBAN on 2012-02-22)</option>
<option
  
  value="JCROMIE/B-Generate-1.12_06"
>1.12_06 DEV
  (JCROMIE on 2008-02-24)</option>
<option
  
  value="JCROMIE/B-Generate-1.12_05"
>1.12_05 DEV
  (JCROMIE on 2008-02-21)</option>
<option
  
  value="JCROMIE/B-Generate-1.12_04"
>1.12_04 DEV
  (JCROMIE on 2008-02-06)</option>
<option
  
  value="JJORE/B-Generate-1.12_03"
>1.12_03 DEV
  (JJORE on 2008-02-06)</option>
<option
  
  value="JCROMIE/B-Generate-1.12_03"
>1.12_03 DEV
  (JCROMIE on 2008-02-01)</option>
<option
  
  value="JJORE/B-Generate-1.11"
>1.11
  (JJORE on 2007-11-05)</option>
<option
  
  value="ABERGMAN/B-Generate-1.06"
>1.06
  (ABERGMAN on 2002-07-28)</option>
<option
  
  value="SIMON/B-Generate-1.01"
>1.01
  (SIMON on 2002-05-02)</option>
<optgroup label="BackPAN">'
<option
  
  value="RURBAN/B-Generate-1.47"
>1.47
  (RURBAN on 2012-10-11)</option>
<option
  
  value="RURBAN/B-Generate-1.46"
>1.46
  (RURBAN on 2012-08-25)</option>
<option
  
  value="RURBAN/B-Generate-1.45"
>1.45
  (RURBAN on 2012-07-20)</option>
<option
  
  value="RURBAN/B-Generate-1.44"
>1.44
  (RURBAN on 2012-03-07)</option>
<option
  
  value="RURBAN/B-Generate-1.42"
>1.42
  (RURBAN on 2012-02-12)</option>
<option
  
  value="RURBAN/B-Generate-1.41"
>1.41
  (RURBAN on 2012-02-11)</option>
<option
  
  value="RURBAN/B-Generate-1.40"
>1.40
  (RURBAN on 2012-01-30)</option>
<option
  
  value="RURBAN/B-Generate-1.39"
>1.39
  (RURBAN on 2011-10-24)</option>
<option
  
  value="RURBAN/B-Generate-1.38"
>1.38
  (RURBAN on 2011-10-19)</option>
<option
  
  value="RURBAN/B-Generate-1.37"
>1.37
  (RURBAN on 2011-07-22)</option>
<option
  
  value="RURBAN/B-Generate-1.36"
>1.36
  (RURBAN on 2011-06-13)</option>
<option
  
  value="RURBAN/B-Generate-1.35"
>1.35
  (RURBAN on 2011-06-11)</option>
<option
  
  value="RURBAN/B-Generate-1.34"
>1.34
  (RURBAN on 2010-11-27)</option>
<option
  
  value="RURBAN/B-Generate-1.33"
>1.33
  (RURBAN on 2010-09-08)</option>
<option
  
  value="RURBAN/B-Generate-1.3202"
>1.3202
  (RURBAN on 2010-09-06)</option>
<option
  
  value="RURBAN/B-Generate-1.3201"
>1.3201
  (RURBAN on 2010-09-03)</option>
<option
  
  value="RURBAN/B-Generate-1.32"
>1.32
  (RURBAN on 2010-09-03)</option>
<option
  
  value="RURBAN/B-Generate-1.31"
>1.31
  (RURBAN on 2010-08-30)</option>
<option
  
  value="RURBAN/B-Generate-1.3001"
>1.3001
  (RURBAN on 2010-08-30)</option>
<option
  
  value="RURBAN/B-Generate-1.30"
>1.30
  (RURBAN on 2010-08-29)</option>
<option
  
  value="RURBAN/B-Generate-1.29"
>1.29
  (RURBAN on 2010-08-24)</option>
<option
  
  value="RURBAN/B-Generate-1.28"
>1.28
  (RURBAN on 2010-08-20)</option>
<option
  
  value="RURBAN/B-Generate-1.27"
>1.27
  (RURBAN on 2010-04-10)</option>
<option
  
  value="RURBAN/B-Generate-1.26"
>1.26
  (RURBAN on 2010-01-14)</option>
<option
  
  value="RURBAN/B-Generate-1.25"
>1.25
  (RURBAN on 2010-01-12)</option>
<option
  
  value="RURBAN/B-Generate-1.24"
>1.24
  (RURBAN on 2009-12-07)</option>
<option
  
  value="RURBAN/B-Generate-1.23"
>1.23
  (RURBAN on 2009-12-07)</option>
<option
  
  value="RURBAN/B-Generate-1.22"
>1.22
  (RURBAN on 2009-11-27)</option>
<option
  
  value="RURBAN/B-Generate-1.21"
>1.21
  (RURBAN on 2009-11-23)</option>
<option
  
  value="RURBAN/B-Generate-1.20"
>1.20
  (RURBAN on 2009-01-18)</option>
<option
  
  value="RURBAN/B-Generate-1.19"
>1.19
  (RURBAN on 2008-12-23)</option>
<option
  
  value="RURBAN/B-Generate-1.18"
>1.18
  (RURBAN on 2008-12-22)</option>
<option
  
  value="RURBAN/B-Generate-1.17"
>1.17
  (RURBAN on 2008-12-22)</option>
<option
  
  value="RURBAN/B-Generate-1.16"
>1.16
  (RURBAN on 2008-12-21)</option>
<option
  
  value="RURBAN/B-Generate-1.15"
>1.15
  (RURBAN on 2008-12-20)</option>
<option
  
  value="RURBAN/B-Generate-1.14"
>1.14
  (RURBAN on 2008-12-18)</option>
<option
  
  value="RURBAN/B-Generate-1.13"
>1.13
  (RURBAN on 2008-08-02)</option>
<option
  
  value="RURBAN/B-Generate-1.12_10"
>1.12_10 DEV
  (RURBAN on 2008-07-26)</option>
<option
  
  value="RURBAN/B-Generate-1.12_09"
>1.12_09 DEV
  (RURBAN on 2008-06-28)</option>
<option
  
  value="RURBAN/B-Generate-1.12_08"
>1.12_08 DEV
  (RURBAN on 2008-06-26)</option>
<option
  
  value="GRUBER/B-Generate-1.12_07"
>1.12_07 DEV
  (GRUBER on 2008-06-26)</option>
<option
  
  value="JJORE/B-Generate-1.10"
>1.10
  (JJORE on 2007-07-10)</option>
<option
  
  value="JJORE/B-Generate-1.09"
>1.09
  (JJORE on 2007-07-05)</option>
<option
  
  value="MSCHWERN/B-Generate-1.06_2"
>1.06_2 DEV
  (MSCHWERN on 2006-11-12)</option>
<option
  
  value="SWALTERS/B-Generate-1.06_1"
>1.06_1 DEV
  (SWALTERS on 2006-05-04)</option>
<option
  
  value="JJORE/B-Generate-1.08"
>1.08
  (JJORE on 2004-11-26)</option>
<option
  
  value="JJORE/B-Generate-1.07"
>1.07
  (JJORE on 2004-11-26)</option>
<option
  
  value="ABERGMAN/B-Generate-1.05"
>1.05
  (ABERGMAN on 2002-06-27)</option>
<option
  
  value="ABERGMAN/B-Generate-1.04"
>1.04
  (ABERGMAN on 2002-06-27)</option>
<option
  
  value="ABERGMAN/B-Generate-1.03"
>1.03
  (ABERGMAN on 2002-06-26)</option>
<option
  
  value="SIMON/B-Generate-1.00"
>1.00
  (SIMON on 2001-09-01)</option>
<option
  
  value="SIMON/B-Generate-0.07"
>0.07
  (SIMON on 2001-06-04)</option>
<option
  
  value="SIMON/B-Generate-0.06"
>0.06
  (SIMON on 2001-05-29)</option>
<option
  
  value="SIMON/B-Generate-0.04"
>0.04
  (SIMON on 2001-03-21)</option>
<option
  
  value="SIMON/B-Generate-0.03"
>0.03
  (SIMON on 2001-01-10)</option>
<option
  
  value="SIMON/B-Generate-0.02"
>0.02
  (SIMON on 2001-01-05)</option>
<option
  
  value="SIMON/B-Generate-0.01"
>0.01
  (SIMON on 2000-12-23)</option>
</optgroup>
</select>
    </li>
    <li class="version-diff">
<select onchange="document.location.href='/release/RURBAN/B-Generate-1.56/diff/' + encodeURIComponent(this.value) + '/lib/B/Generate.pm'
" class="form-control tool-bar-form">
  <option disabled selected>Diff with version</option>
<option
  disabled
  value="RURBAN/B-Generate-1.56"
>1.56
  (RURBAN on 2017-12-20)</option>
<option
  
  value="RURBAN/B-Generate-1.55"
>1.55
  (RURBAN on 2017-02-23)</option>
<option
  
  value="RURBAN/B-Generate-1.54"
>1.54
  (RURBAN on 2016-05-26)</option>
<option
  
  value="RURBAN/B-Generate-1.53"
>1.53
  (RURBAN on 2015-05-04)</option>
<option
  
  value="RURBAN/B-Generate-1.52"
>1.52
  (RURBAN on 2015-05-03)</option>
<option
  
  value="RURBAN/B-Generate-1.51"
>1.51
  (RURBAN on 2015-05-02)</option>
<option
  
  value="RURBAN/B-Generate-1.50"
>1.50
  (RURBAN on 2014-12-24)</option>
<option
  
  value="RURBAN/B-Generate-1.49"
>1.49
  (RURBAN on 2014-08-08)</option>
<option
  
  value="RURBAN/B-Generate-1.48"
>1.48
  (RURBAN on 2013-09-30)</option>
<option
  
  value="RURBAN/B-Generate-1.43"
>1.43
  (RURBAN on 2012-02-22)</option>
<option
  
  value="JCROMIE/B-Generate-1.12_06"
>1.12_06 DEV
  (JCROMIE on 2008-02-24)</option>
<option
  
  value="JCROMIE/B-Generate-1.12_05"
>1.12_05 DEV
  (JCROMIE on 2008-02-21)</option>
<option
  
  value="JCROMIE/B-Generate-1.12_04"
>1.12_04 DEV
  (JCROMIE on 2008-02-06)</option>
<option
  
  value="JJORE/B-Generate-1.12_03"
>1.12_03 DEV
  (JJORE on 2008-02-06)</option>
<option
  
  value="JCROMIE/B-Generate-1.12_03"
>1.12_03 DEV
  (JCROMIE on 2008-02-01)</option>
<option
  
  value="JJORE/B-Generate-1.11"
>1.11
  (JJORE on 2007-11-05)</option>
<option
  
  value="ABERGMAN/B-Generate-1.06"
>1.06
  (ABERGMAN on 2002-07-28)</option>
<option
  
  value="SIMON/B-Generate-1.01"
>1.01
  (SIMON on 2002-05-02)</option>
<optgroup label="BackPAN">'
<option
  
  value="RURBAN/B-Generate-1.47"
>1.47
  (RURBAN on 2012-10-11)</option>
<option
  
  value="RURBAN/B-Generate-1.46"
>1.46
  (RURBAN on 2012-08-25)</option>
<option
  
  value="RURBAN/B-Generate-1.45"
>1.45
  (RURBAN on 2012-07-20)</option>
<option
  
  value="RURBAN/B-Generate-1.44"
>1.44
  (RURBAN on 2012-03-07)</option>
<option
  
  value="RURBAN/B-Generate-1.42"
>1.42
  (RURBAN on 2012-02-12)</option>
<option
  
  value="RURBAN/B-Generate-1.41"
>1.41
  (RURBAN on 2012-02-11)</option>
<option
  
  value="RURBAN/B-Generate-1.40"
>1.40
  (RURBAN on 2012-01-30)</option>
<option
  
  value="RURBAN/B-Generate-1.39"
>1.39
  (RURBAN on 2011-10-24)</option>
<option
  
  value="RURBAN/B-Generate-1.38"
>1.38
  (RURBAN on 2011-10-19)</option>
<option
  
  value="RURBAN/B-Generate-1.37"
>1.37
  (RURBAN on 2011-07-22)</option>
<option
  
  value="RURBAN/B-Generate-1.36"
>1.36
  (RURBAN on 2011-06-13)</option>
<option
  
  value="RURBAN/B-Generate-1.35"
>1.35
  (RURBAN on 2011-06-11)</option>
<option
  
  value="RURBAN/B-Generate-1.34"
>1.34
  (RURBAN on 2010-11-27)</option>
<option
  
  value="RURBAN/B-Generate-1.33"
>1.33
  (RURBAN on 2010-09-08)</option>
<option
  
  value="RURBAN/B-Generate-1.3202"
>1.3202
  (RURBAN on 2010-09-06)</option>
<option
  
  value="RURBAN/B-Generate-1.3201"
>1.3201
  (RURBAN on 2010-09-03)</option>
<option
  
  value="RURBAN/B-Generate-1.32"
>1.32
  (RURBAN on 2010-09-03)</option>
<option
  
  value="RURBAN/B-Generate-1.31"
>1.31
  (RURBAN on 2010-08-30)</option>
<option
  
  value="RURBAN/B-Generate-1.3001"
>1.3001
  (RURBAN on 2010-08-30)</option>
<option
  
  value="RURBAN/B-Generate-1.30"
>1.30
  (RURBAN on 2010-08-29)</option>
<option
  
  value="RURBAN/B-Generate-1.29"
>1.29
  (RURBAN on 2010-08-24)</option>
<option
  
  value="RURBAN/B-Generate-1.28"
>1.28
  (RURBAN on 2010-08-20)</option>
<option
  
  value="RURBAN/B-Generate-1.27"
>1.27
  (RURBAN on 2010-04-10)</option>
<option
  
  value="RURBAN/B-Generate-1.26"
>1.26
  (RURBAN on 2010-01-14)</option>
<option
  
  value="RURBAN/B-Generate-1.25"
>1.25
  (RURBAN on 2010-01-12)</option>
<option
  
  value="RURBAN/B-Generate-1.24"
>1.24
  (RURBAN on 2009-12-07)</option>
<option
  
  value="RURBAN/B-Generate-1.23"
>1.23
  (RURBAN on 2009-12-07)</option>
<option
  
  value="RURBAN/B-Generate-1.22"
>1.22
  (RURBAN on 2009-11-27)</option>
<option
  
  value="RURBAN/B-Generate-1.21"
>1.21
  (RURBAN on 2009-11-23)</option>
<option
  
  value="RURBAN/B-Generate-1.20"
>1.20
  (RURBAN on 2009-01-18)</option>
<option
  
  value="RURBAN/B-Generate-1.19"
>1.19
  (RURBAN on 2008-12-23)</option>
<option
  
  value="RURBAN/B-Generate-1.18"
>1.18
  (RURBAN on 2008-12-22)</option>
<option
  
  value="RURBAN/B-Generate-1.17"
>1.17
  (RURBAN on 2008-12-22)</option>
<option
  
  value="RURBAN/B-Generate-1.16"
>1.16
  (RURBAN on 2008-12-21)</option>
<option
  
  value="RURBAN/B-Generate-1.15"
>1.15
  (RURBAN on 2008-12-20)</option>
<option
  
  value="RURBAN/B-Generate-1.14"
>1.14
  (RURBAN on 2008-12-18)</option>
<option
  
  value="RURBAN/B-Generate-1.13"
>1.13
  (RURBAN on 2008-08-02)</option>
<option
  
  value="RURBAN/B-Generate-1.12_10"
>1.12_10 DEV
  (RURBAN on 2008-07-26)</option>
<option
  
  value="RURBAN/B-Generate-1.12_09"
>1.12_09 DEV
  (RURBAN on 2008-06-28)</option>
<option
  
  value="RURBAN/B-Generate-1.12_08"
>1.12_08 DEV
  (RURBAN on 2008-06-26)</option>
<option
  
  value="GRUBER/B-Generate-1.12_07"
>1.12_07 DEV
  (GRUBER on 2008-06-26)</option>
<option
  
  value="JJORE/B-Generate-1.10"
>1.10
  (JJORE on 2007-07-10)</option>
<option
  
  value="JJORE/B-Generate-1.09"
>1.09
  (JJORE on 2007-07-05)</option>
<option
  
  value="MSCHWERN/B-Generate-1.06_2"
>1.06_2 DEV
  (MSCHWERN on 2006-11-12)</option>
<option
  
  value="SWALTERS/B-Generate-1.06_1"
>1.06_1 DEV
  (SWALTERS on 2006-05-04)</option>
<option
  
  value="JJORE/B-Generate-1.08"
>1.08
  (JJORE on 2004-11-26)</option>
<option
  
  value="JJORE/B-Generate-1.07"
>1.07
  (JJORE on 2004-11-26)</option>
<option
  
  value="ABERGMAN/B-Generate-1.05"
>1.05
  (ABERGMAN on 2002-06-27)</option>
<option
  
  value="ABERGMAN/B-Generate-1.04"
>1.04
  (ABERGMAN on 2002-06-27)</option>
<option
  
  value="ABERGMAN/B-Generate-1.03"
>1.03
  (ABERGMAN on 2002-06-26)</option>
<option
  
  value="SIMON/B-Generate-1.00"
>1.00
  (SIMON on 2001-09-01)</option>
<option
  
  value="SIMON/B-Generate-0.07"
>0.07
  (SIMON on 2001-06-04)</option>
<option
  
  value="SIMON/B-Generate-0.06"
>0.06
  (SIMON on 2001-05-29)</option>
<option
  
  value="SIMON/B-Generate-0.04"
>0.04
  (SIMON on 2001-03-21)</option>
<option
  
  value="SIMON/B-Generate-0.03"
>0.03
  (SIMON on 2001-01-10)</option>
<option
  
  value="SIMON/B-Generate-0.02"
>0.02
  (SIMON on 2001-01-05)</option>
<option
  
  value="SIMON/B-Generate-0.01"
>0.01
  (SIMON on 2000-12-23)</option>
</optgroup>
</select>
    </li>

    <li>
<ul class="dependencies">
  <li class="nav-header">Dependencies</li>
  <li><a href="https://metacpan.org/pod/B" title="B" class="ellipsis">B</a></li>
  <li><a href="https://metacpan.org/pod/ExtUtils::CBuilder" title="ExtUtils::CBuilder" class="ellipsis">ExtUtils::CBuilder</a></li>
  <li><a href="https://metacpan.org/pod/ExtUtils::Embed" title="ExtUtils::Embed" class="ellipsis">ExtUtils::Embed</a></li>
  <li><i class="ttip" title="dynamic_config enabled">and possibly others</i></li>
  <li>
    <hr>
  </li>
  <li>
    <a href="https://metacpan.org/module/B::Generate/requires">Reverse dependencies</a>
  </li>
  <li>
    <a href="http://deps.cpantesters.org/?module=B%3A%3AGenerate">CPAN Testers List</a>
  </li>
  <li>
    <a href="https://cpandeps.grinnz.com/?dist=B-Generate">Dependency graph</a>
  </li>
</ul>
    </li>
    <li class="nav-header">Permalinks</li>
    <li>
      <a href="https://metacpan.org/release/RURBAN/B-Generate-1.56/view/lib/B/Generate.pm">This version</a>
    </li>
    <li>
      <a href="./B::Generate.html">Latest version</a>
    </li>
    <li>
<div class="plussers">
<div class="nav-header">++ed by:</div>
<div>
<a class="display-all" href="https://metacpan.org/author/DELON"><img src="https://www.gravatar.com/avatar/8a316157de5eaa39f351b1725c4641d0?d=identicon&amp;s=20" title="DELON" alt="DELON"></a>
<a class="display-all" href="https://metacpan.org/author/RSCHABER"><img src="https://www.gravatar.com/avatar/8735b8d5583ee0a0155a41f993cab4f3?d=identicon&amp;s=20" title="RSCHABER" alt="RSCHABER"></a>
<a class="display-all" href="https://metacpan.org/author/KES"><img src="https://www.gravatar.com/avatar/e8530f00b43b4f6a056f8ad4ee52ea47?d=identicon&amp;s=20" title="KES" alt="KES"></a>
</div>
<!-- Display counts of plussers-->
<div>
    <a href="https://metacpan.org/dist/B-Generate/plussers">3 PAUSE users</a>
</div>
</div>
    </li>
    <li>
<div id="metacpan_contributors">
  <div>
    <button class="btn-link"
      onclick="$(this).hide(); $('#metacpan_contributors ul').slideDown(); return false;"
    >and 1 contributors</button>
  </div>
  <ul style="display: none">
    <li class="contributor"
    >
      Simon Cozens
    </li>
  </ul>
</div>
    </li>
              </ul>
            </div>
          </nav>
          <div class="content-navigation">
<div class="breadcrumbs">
  <span>
    <a data-keyboard-shortcut="g a" rel="author" href="https://metacpan.org/author/RURBAN" class="author-name">Reini Urban</a>
  </span>
  <span>&nbsp;/&nbsp;</span>
  <div class="release dist-release status-latest maturity-released">
    <span class="dropdown"><b class="caret"></b></span>
<select onchange="document.location.href=&#39;/release/&#39;+this.value+&#39;/view/lib/B/Generate.pm&#39;" class="">
<option
  selected
  value="RURBAN/B-Generate-1.56"
>1.56
  (RURBAN on 2017-12-20)</option>
<option
  
  value="RURBAN/B-Generate-1.55"
>1.55
  (RURBAN on 2017-02-23)</option>
<option
  
  value="RURBAN/B-Generate-1.54"
>1.54
  (RURBAN on 2016-05-26)</option>
<option
  
  value="RURBAN/B-Generate-1.53"
>1.53
  (RURBAN on 2015-05-04)</option>
<option
  
  value="RURBAN/B-Generate-1.52"
>1.52
  (RURBAN on 2015-05-03)</option>
<option
  
  value="RURBAN/B-Generate-1.51"
>1.51
  (RURBAN on 2015-05-02)</option>
<option
  
  value="RURBAN/B-Generate-1.50"
>1.50
  (RURBAN on 2014-12-24)</option>
<option
  
  value="RURBAN/B-Generate-1.49"
>1.49
  (RURBAN on 2014-08-08)</option>
<option
  
  value="RURBAN/B-Generate-1.48"
>1.48
  (RURBAN on 2013-09-30)</option>
<option
  
  value="RURBAN/B-Generate-1.43"
>1.43
  (RURBAN on 2012-02-22)</option>
<option
  
  value="JCROMIE/B-Generate-1.12_06"
>1.12_06 DEV
  (JCROMIE on 2008-02-24)</option>
<option
  
  value="JCROMIE/B-Generate-1.12_05"
>1.12_05 DEV
  (JCROMIE on 2008-02-21)</option>
<option
  
  value="JCROMIE/B-Generate-1.12_04"
>1.12_04 DEV
  (JCROMIE on 2008-02-06)</option>
<option
  
  value="JJORE/B-Generate-1.12_03"
>1.12_03 DEV
  (JJORE on 2008-02-06)</option>
<option
  
  value="JCROMIE/B-Generate-1.12_03"
>1.12_03 DEV
  (JCROMIE on 2008-02-01)</option>
<option
  
  value="JJORE/B-Generate-1.11"
>1.11
  (JJORE on 2007-11-05)</option>
<option
  
  value="ABERGMAN/B-Generate-1.06"
>1.06
  (ABERGMAN on 2002-07-28)</option>
<option
  
  value="SIMON/B-Generate-1.01"
>1.01
  (SIMON on 2002-05-02)</option>
<optgroup label="BackPAN">'
<option
  
  value="RURBAN/B-Generate-1.47"
>1.47
  (RURBAN on 2012-10-11)</option>
<option
  
  value="RURBAN/B-Generate-1.46"
>1.46
  (RURBAN on 2012-08-25)</option>
<option
  
  value="RURBAN/B-Generate-1.45"
>1.45
  (RURBAN on 2012-07-20)</option>
<option
  
  value="RURBAN/B-Generate-1.44"
>1.44
  (RURBAN on 2012-03-07)</option>
<option
  
  value="RURBAN/B-Generate-1.42"
>1.42
  (RURBAN on 2012-02-12)</option>
<option
  
  value="RURBAN/B-Generate-1.41"
>1.41
  (RURBAN on 2012-02-11)</option>
<option
  
  value="RURBAN/B-Generate-1.40"
>1.40
  (RURBAN on 2012-01-30)</option>
<option
  
  value="RURBAN/B-Generate-1.39"
>1.39
  (RURBAN on 2011-10-24)</option>
<option
  
  value="RURBAN/B-Generate-1.38"
>1.38
  (RURBAN on 2011-10-19)</option>
<option
  
  value="RURBAN/B-Generate-1.37"
>1.37
  (RURBAN on 2011-07-22)</option>
<option
  
  value="RURBAN/B-Generate-1.36"
>1.36
  (RURBAN on 2011-06-13)</option>
<option
  
  value="RURBAN/B-Generate-1.35"
>1.35
  (RURBAN on 2011-06-11)</option>
<option
  
  value="RURBAN/B-Generate-1.34"
>1.34
  (RURBAN on 2010-11-27)</option>
<option
  
  value="RURBAN/B-Generate-1.33"
>1.33
  (RURBAN on 2010-09-08)</option>
<option
  
  value="RURBAN/B-Generate-1.3202"
>1.3202
  (RURBAN on 2010-09-06)</option>
<option
  
  value="RURBAN/B-Generate-1.3201"
>1.3201
  (RURBAN on 2010-09-03)</option>
<option
  
  value="RURBAN/B-Generate-1.32"
>1.32
  (RURBAN on 2010-09-03)</option>
<option
  
  value="RURBAN/B-Generate-1.31"
>1.31
  (RURBAN on 2010-08-30)</option>
<option
  
  value="RURBAN/B-Generate-1.3001"
>1.3001
  (RURBAN on 2010-08-30)</option>
<option
  
  value="RURBAN/B-Generate-1.30"
>1.30
  (RURBAN on 2010-08-29)</option>
<option
  
  value="RURBAN/B-Generate-1.29"
>1.29
  (RURBAN on 2010-08-24)</option>
<option
  
  value="RURBAN/B-Generate-1.28"
>1.28
  (RURBAN on 2010-08-20)</option>
<option
  
  value="RURBAN/B-Generate-1.27"
>1.27
  (RURBAN on 2010-04-10)</option>
<option
  
  value="RURBAN/B-Generate-1.26"
>1.26
  (RURBAN on 2010-01-14)</option>
<option
  
  value="RURBAN/B-Generate-1.25"
>1.25
  (RURBAN on 2010-01-12)</option>
<option
  
  value="RURBAN/B-Generate-1.24"
>1.24
  (RURBAN on 2009-12-07)</option>
<option
  
  value="RURBAN/B-Generate-1.23"
>1.23
  (RURBAN on 2009-12-07)</option>
<option
  
  value="RURBAN/B-Generate-1.22"
>1.22
  (RURBAN on 2009-11-27)</option>
<option
  
  value="RURBAN/B-Generate-1.21"
>1.21
  (RURBAN on 2009-11-23)</option>
<option
  
  value="RURBAN/B-Generate-1.20"
>1.20
  (RURBAN on 2009-01-18)</option>
<option
  
  value="RURBAN/B-Generate-1.19"
>1.19
  (RURBAN on 2008-12-23)</option>
<option
  
  value="RURBAN/B-Generate-1.18"
>1.18
  (RURBAN on 2008-12-22)</option>
<option
  
  value="RURBAN/B-Generate-1.17"
>1.17
  (RURBAN on 2008-12-22)</option>
<option
  
  value="RURBAN/B-Generate-1.16"
>1.16
  (RURBAN on 2008-12-21)</option>
<option
  
  value="RURBAN/B-Generate-1.15"
>1.15
  (RURBAN on 2008-12-20)</option>
<option
  
  value="RURBAN/B-Generate-1.14"
>1.14
  (RURBAN on 2008-12-18)</option>
<option
  
  value="RURBAN/B-Generate-1.13"
>1.13
  (RURBAN on 2008-08-02)</option>
<option
  
  value="RURBAN/B-Generate-1.12_10"
>1.12_10 DEV
  (RURBAN on 2008-07-26)</option>
<option
  
  value="RURBAN/B-Generate-1.12_09"
>1.12_09 DEV
  (RURBAN on 2008-06-28)</option>
<option
  
  value="RURBAN/B-Generate-1.12_08"
>1.12_08 DEV
  (RURBAN on 2008-06-26)</option>
<option
  
  value="GRUBER/B-Generate-1.12_07"
>1.12_07 DEV
  (GRUBER on 2008-06-26)</option>
<option
  
  value="JJORE/B-Generate-1.10"
>1.10
  (JJORE on 2007-07-10)</option>
<option
  
  value="JJORE/B-Generate-1.09"
>1.09
  (JJORE on 2007-07-05)</option>
<option
  
  value="MSCHWERN/B-Generate-1.06_2"
>1.06_2 DEV
  (MSCHWERN on 2006-11-12)</option>
<option
  
  value="SWALTERS/B-Generate-1.06_1"
>1.06_1 DEV
  (SWALTERS on 2006-05-04)</option>
<option
  
  value="JJORE/B-Generate-1.08"
>1.08
  (JJORE on 2004-11-26)</option>
<option
  
  value="JJORE/B-Generate-1.07"
>1.07
  (JJORE on 2004-11-26)</option>
<option
  
  value="ABERGMAN/B-Generate-1.05"
>1.05
  (ABERGMAN on 2002-06-27)</option>
<option
  
  value="ABERGMAN/B-Generate-1.04"
>1.04
  (ABERGMAN on 2002-06-27)</option>
<option
  
  value="ABERGMAN/B-Generate-1.03"
>1.03
  (ABERGMAN on 2002-06-26)</option>
<option
  
  value="SIMON/B-Generate-1.00"
>1.00
  (SIMON on 2001-09-01)</option>
<option
  
  value="SIMON/B-Generate-0.07"
>0.07
  (SIMON on 2001-06-04)</option>
<option
  
  value="SIMON/B-Generate-0.06"
>0.06
  (SIMON on 2001-05-29)</option>
<option
  
  value="SIMON/B-Generate-0.04"
>0.04
  (SIMON on 2001-03-21)</option>
<option
  
  value="SIMON/B-Generate-0.03"
>0.03
  (SIMON on 2001-01-10)</option>
<option
  
  value="SIMON/B-Generate-0.02"
>0.02
  (SIMON on 2001-01-05)</option>
<option
  
  value="SIMON/B-Generate-0.01"
>0.01
  (SIMON on 2000-12-23)</option>
</optgroup>
</select>
    <a data-keyboard-shortcut="g d" class="release-name" href="https://metacpan.org/dist/B-Generate">B-Generate-1.56</a>
  </div>
<span class="river-gauge-gauge">
  <svg width="24px"
       height="15px"
       version="1.1"
       xmlns="http://www.w3.org/2000/svg"
       xmlns:xlink="http://www.w3.org/1999/xlink">

    <g>
      <title>        River stage two &#10;
          • 10 direct dependents &#10;          • 14 total dependents
      </title>

      <rect x="0"  y="0" width="4" height="15" fill="#7ea3f2" />
      <rect x="5"  y="0" width="4" height="15" fill="#7ea3f2" />
      <rect x="10"  y="0" width="4" height="15" fill="#e4e2e2" />
      <rect x="15"  y="0" width="4" height="15" fill="#e4e2e2" />
      <rect x="20"  y="0" width="4" height="15" fill="#e4e2e2" />
    </g>
  </svg>

</span>
<div id="B-Generate-fav" class="logged_in">
<form action="https://metacpan.org/account/favorite/add" style="display: inline" onsubmit="return favDistribution(this)">
    <input type="hidden" name="remove" value="0">
    <input type="hidden" name="release" value="B-Generate-1.56">
    <input type="hidden" name="author" value="RURBAN">
    <input type="hidden" name="distribution" value="B-Generate">
    <button type="submit" class="favorite highlight"><span>3</span> ++</button>
</form>
</div>
<div class="logged_out">
<a href="./B::Generate.html" onclick="alert('Please sign in to add favorites'); return false" class="favorite highlight">
<span>3</span> ++</a>
</div>
   / <span>B::Generate</span>
</div>
          </div>
          <main class="content">


<nav class="toc">
  <div class="toc-header"><strong>Contents</strong></div>
<ul>
  <li><a href="./B::Generate.html#NAME">NAME</a></li>
  <li><a href="./B::Generate.html#SYNOPSIS">SYNOPSIS</a></li>
  <li><a href="./B::Generate.html#WARNING">WARNING</a></li>
  <li><a href="./B::Generate.html#DESCRIPTION">DESCRIPTION</a>
    <ul>
      <li><a href="./B::Generate.html#OTHER-METHODS">OTHER METHODS</a></li>
      <li><a href="./B::Generate.html#EXPORT">EXPORT</a></li>
    </ul>
  </li>
  <li><a href="./B::Generate.html#AUTHOR">AUTHOR</a></li>
  <li><a href="./B::Generate.html#MAINTAINERS">MAINTAINERS</a></li>
  <li><a href="./B::Generate.html#LICENSE">LICENSE</a></li>
  <li><a href="./B::Generate.html#SEE-ALSO">SEE ALSO</a></li>
</ul></nav>
<div class="pod anchors">
<h1 id="NAME">NAME</h1>

<p>B::Generate - Create your own op trees.</p>

<h1 id="SYNOPSIS">SYNOPSIS</h1>

<pre><code>    use B::Generate;
    # Do nothing, slowly.
    CHECK {
        my $null = new B::OP(&quot;null&quot;,0);
        my $enter = new B::OP(&quot;enter&quot;,0);
        my $cop = new B::COP(0, &quot;hiya&quot;, 0);
        my $leave = new B::LISTOP(&quot;leave&quot;, 0, $enter, $null);
        $leave-&gt;children(3);
        $enter-&gt;sibling($cop);
        $enter-&gt;next($cop);
        $cop-&gt;sibling($null);
        $null-&gt;next($leave);
        $cop-&gt;next($leave);

        # Tell Perl where to find our tree.
        B::main_root($leave);
        B::main_start($enter);
    }</code></pre>

<h1 id="WARNING">WARNING</h1>

<p>This module will create segmentation faults if you don&#39;t know how to use it properly. Further warning: sometimes <b>I</b> don&#39;t know how to use it properly.</p>

<p>There <b>are</b> lots of other methods and utility functions, but they are not documented here. This is deliberate, rather than just through laziness. You are expected to have read the Perl and XS sources to this module before attempting to do anything with it.</p>

<h1 id="DESCRIPTION">DESCRIPTION</h1>

<p>The <code>B</code> module allows you to examine the Perl op tree at runtime, in Perl space; it&#39;s the basis of the Perl compiler. But what it doesn&#39;t let you do is manipulate that op tree: it won&#39;t let you create new ops, or modify old ones. Now you can.</p>

<p>Well, if you&#39;re intimately familiar with Perl&#39;s internals, you can.</p>

<p><code>B::Generate</code> turns <code>B</code>&#39;s accessor methods into get-set methods. Hence, instead of merely saying</p>

<pre><code>    $op2 = $op-&gt;next;</code></pre>

<p>you can now say</p>

<pre><code>    $op-&gt;next($op2);</code></pre>

<p>to set the next op in the chain. It also adds constructor methods to create new ops. This is where it gets really hairy.</p>

<pre><code>    new B::OP     ( type, flags )
    new B::UNOP   ( type, flags, first )
    new B::BINOP  ( type, flags, first, last )
    new B::LOGOP  ( type, flags, first, other )
    new B::LISTOP ( type, flags, first, last )
    new B::SVOP   ( type, flags, sv )
    new B::COP    ( flags, name, first )</code></pre>

<p>In all of the above constructors, <code>type</code> is either a numeric value representing the op type (<code>62</code> is the addition operator in certain perl versions, for instance) or the name of the op. (<code>&quot;add&quot;</code>)</p>

<p>Incidentally, if you know about custom ops and have registed them properly with the interpreter, you can create custom ops by name: <code>new B::OP(&quot;mycustomop&quot;,0)</code>, or whatever.</p>

<p><code>first</code>, <code>last</code> and <code>other</code> are ops to be attached to the current op; these should be <code>B::OP</code> objects. If you haven&#39;t created the ops yet, don&#39;t worry; give a false value, and fill them in later:</p>

<pre><code>    $x = new B::UNOP(&quot;negate&quot;, 0, undef);
    # ... create some more ops ...
    $x-&gt;first($y);</code></pre>

<p>In addition, one may create a new <code>nextstate</code> operator with</p>

<pre><code>    newstate B::op ( flags, label, op)</code></pre>

<p>in the same manner as <code>B::COP::new</code> - this will also, however, add the <code>lineseq</code> op.</p>

<p>Finally, you can set the main root and the starting op by passing ops to the <code>B::main_root</code> and <code>B::main_start</code> functions.</p>

<p>This module can obviously be used for all sorts of fun and optimizational purposes. One example will be in conjuction with source filters; have your source filter parse an input file in a foreign language, create an op tree for it and get Perl to execute it. Then email me and tell me how you did it. And why.</p>

<h2 id="OTHER-METHODS"><a id="OTHER"></a>OTHER METHODS</h2>

<dl>

<dt id="B::SVOP-&gt;sv()"><a id="B"></a><a id="B::SVOP--sv"></a>B::SVOP-&gt;sv()</dt>
<dd>

<p>Returns the SV value instead of the <code>B::SV</code> object. For instance:</p>

<pre><code>    $b_sv = $svop-&gt;sv;
    if ($b_sv-&gt;sv == 3) {
        print &quot;SVOP&#39;s SV has an IV of 3\n&quot;
    }</code></pre>

<p>But to set the SV you need a proper B::SV object.</p>

</dd>
<dt id="$op-&gt;dump"><a id="op--dump"></a>$op-&gt;dump</dt>
<dd>

<p>Runs <code>Perl_op_dump</code> on an op; this is roughly equivalent to <code>B::Debug</code>, but not quite.</p>

</dd>
<dt id="$b_sv-&gt;dump"><a id="b_sv--dump"></a>$b_sv-&gt;dump</dt>
<dd>

<p>Runs <code>Perl_sv_dump</code> on an SV; this is exactly equivalent to <code>Devel::Peek::dump($b_sv-&gt;sv)</code></p>

</dd>
<dt id="$b_op-&gt;linklist"><a id="b_op--linklist"></a>$b_op-&gt;linklist</dt>
<dd>

<p>Sets the <code>op_next</code> pointers in the tree in correct execution order, overwriting the old <code>next</code> pointers. You <b>need</b> to do this once you&#39;ve created an op tree for execution, unless you&#39;ve carefully threaded it together yourself.</p>

</dd>
<dt id="$b_op-&gt;scope"><a id="b_op--scope"></a>$b_op-&gt;scope</dt>
<dd>

<p>Create a surrounding scope for the b_op, &quot;parenthesize&quot; it.</p>

<p>Creates on OPf_PARENS (already parenthesized by the parser) a full lineseq, enter, b_op, leave sequence.</p>

<p>Otherwise just scope, b_op.</p>

</dd>
<dt id="B::SVOP-&gt;new_svrv-(-type,-flags,-sv-)"><a id="B1"></a><a id="B::SVOP--new_svrv---type--flags--sv"></a>B::SVOP-&gt;new_svrv ( type, flags, sv )</dt>
<dd>

<p>Similar to B::SVOP-&gt;new ( type, flags, sv ), it just creates a new SVOP with an attached sv as SvRV to the given sv.</p>

</dd>
<dt id="$cv-&gt;NEW_with_start-(root,-start)"><a id="cv--NEW_with_start--root--start"></a>$cv-&gt;NEW_with_start (root, start)</dt>
<dd>

<p>Clone the <code>cv</code> with new root and start ops. Note that contrary to <code>cv_clone</code>, the PADLIST and pad index is kept, but the index might point to a different lexical, because the PADLIST indices will be different. See <i>t/new_cv.t</i>.</p>

<p>Warning: <code>$cv-</code>NEW_with_start&gt; is disabled on some strict platforms, like <b>MSWin32</b>. See CPAN RT#28912.</p>

</dd>
<dt id="$b_op-&gt;targ-(-[-targ]-)"><a id="b_op--targ-----targ"></a>$b_op-&gt;targ ( [ targ] )</dt>
<dd>

<p>Get or set the PADOFFSET.</p>

</dd>
</dl>

<h2 id="EXPORT">EXPORT</h2>

<p>None.</p>

<h1 id="AUTHOR">AUTHOR</h1>

<p>Simon Cozens, <code>simon@cpan.org</code> Reini Urban, <code>rurban@cpan.org</code></p>

<h1 id="MAINTAINERS">MAINTAINERS</h1>

<p>Maintained by Reini Urban.</p>

<p>This is just a list of people who have submitted patches to the module:</p>

<p>Josh Jore, Michael Schwern, Jim Cromie, Scott Walters, Reini Urban, Anton Berezin, Dmitry Karasik.</p>

<p>Maintainership permissions do have: Artur Bergman, Chia-liang Kao, Anton Berezin, Jim Cromie, Joshua ben Jore, Michael G Schwern, Matt S Trout, Reini Urban, Scott Walters.</p>

<h1 id="LICENSE">LICENSE</h1>

<p>This module is available under the same licences as perl, the Artistic license and the GPL.</p>

<h1 id="SEE-ALSO"><a id="SEE"></a>SEE ALSO</h1>

<p><a href="https://metacpan.org/pod/B">B</a>, <i>perlguts</i>, <i>op.c</i>, <b>perloptree</b> with <a href="https://metacpan.org/pod/B::C">B::C</a></p></div>

<div id="metacpan_install-instructions-dialog" class="modal fade">
  <div class="modal-dialog">
    <div class="modal-content">
      <div class="modal-header">
        <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
        <h4 class="modal-title">Module Install Instructions</h4>
      </div>
      <div class="modal-body">
        <p>To install B::Generate, copy and paste the appropriate command in to your terminal.</p>
        <p><a href="https://metacpan.org/dist/App-cpanminus/view/bin/cpanm">cpanm</a></p>
        <pre><code>cpanm B::Generate</code></pre>
        <p><a href="https://metacpan.org/pod/CPAN">CPAN shell</a></p>
        <pre><code>perl -MCPAN -e shell
install B::Generate</code></pre>
        <p>For more information on module installation, please visit <a href="https://www.cpan.org/modules/INSTALL.html">the detailed CPAN module installation guide</a>.</p>
      </div>
      <div class="modal-footer">
        <a href="./B::Generate.html#" data-dismiss="modal" class="btn">Close</a>
      </div>
    </div>
  </div>
</div>
          </main>
          <div class="content-pagination">
          </div>
        </div>
        <footer class="footer">
          <div class="footer-container">
            <div class="footer-social">
              <div class="footer-link footer-logo">
                <a href="https://metacpan.org/">
                  <img src="https://metacpan.org/static/images/metacpan-logo.svg" alt="MetaCPAN" />
                </a>
              </div>
              <a class="footer-social-link" href="https://github.com/metacpan">
                <i class="fab fa-github-square"></i>
              </a>
              <a class="footer-social-link" href="https://fosstodon.org/@metacpan">
                <i class="fab fa-mastodon"></i>
              </a>
            </div>
            <div class="footer-links">
              <div class="footer-link">
                  <a href="https://metacpan.org/about">About</a>
              </div>
              <div class="footer-link">
                  <a href="https://metacpan.org/about/sponsors">Sponsor</a>
              </div>
              <div class="footer-link">
                  <a href="https://grep.metacpan.org">grep::cpan</a>
              </div>
              <div class="footer-link">
                  <a href="https://metacpan.org/recent">Recent</a>
              </div>
              <div class="footer-link">
                  <a href="https://metacpan.org/about/faq">FAQ</a>
              </div>
              <div class="footer-link">
                  <a href="https://metacpan.org/tools">Tools</a>
              </div>
              <div class="footer-link">
                  <a href="https://fastapi.metacpan.org/">API</a>
              </div>
              <div class="footer-link">
                  <a href="https://www.perl.org/">Perl.org</a>
              </div>
            </div>
            <div class="footer-sponsors">
              <a class="footer-sponsor-link" target="_blank" href="https://www.bytemark.co.uk/" rel="noopener">
                <img class="footer-sponsor-bytemark" src="https://metacpan.org/static/images/sponsors/bytemark_logo.svg" alt="Bytemark logo">
              </a>
              <a class="footer-sponsor-link" target="_blank" href="https://www.liquidweb.com/" rel="noopener">
                <img class="footer-sponsor-liquidweb" src="https://metacpan.org/static/images/sponsors/liquidweb_logo.png" alt="liquidweb logo">
              </a>
              <a class="footer-sponsor-link" target="_blank" href="https://deriv.com/careers/" rel="noopener">
                <img class="footer-sponsor-deriv" src="https://metacpan.org/static/images/sponsors/deriv.svg" alt="Deriv logo">
              </a>
              <a class="footer-sponsor-link" target="_blank" href="https://geocode.xyz" rel="noopener">
                <img class="footer-sponsor-geocode" src="https://metacpan.org/static/images/sponsors/geocodelogo.svg" alt="Geocode logo">
              </a>
              <a class="footer-sponsor-link" target="_blank" href="https://www.fastly.com/" rel="noopener">
                <img class="footer-sponsor-fastly" src="https://metacpan.org/static/images/sponsors/fastly_logo.svg" alt="Fastly logo">
              </a>
              <a class="footer-sponsor-link" target="_blank" href="https://opencagedata.com" rel="noopener">
                <img class="footer-sponsor-opencage" src="https://metacpan.org/static/images/sponsors/open-cage.svg" alt="OpenCage logo">
              </a>
            </div>
          </div>
        </footer>
        <div class="modal fade" tabindex="-1" role="dialog" id="metacpan_keyboard-shortcuts">
          <div class="modal-dialog">
            <div class="modal-content">
              <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal">&times;</button>
                <h4 class="modal-title">Keyboard Shortcuts</h4>
              </div>
              <div class="modal-body row">
<div class="col-md-6">
  <table class="table keyboard-shortcuts">
    <thead>
      <tr>
        <th></th>
        <th>Global</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td class="keys">
          <kbd>s</kbd>
        </td>
        <td>Focus search bar</td>
      </tr>
      <tr>
        <td class="keys">
          <kbd>?</kbd>
        </td>
        <td>Bring up this help dialog</td>
      </tr>
    </tbody>
  </table>

  <table class="table keyboard-shortcuts">
    <thead>
      <tr>
        <th></th>
        <th>GitHub</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td class="keys">
          <kbd>g</kbd> <kbd>p</kbd>
        </td>
        <td>Go to pull requests</td>
      </tr>
      <tr>
        <td class="keys">
          <kbd>g</kbd> <kbd>i</kbd>
        </td>
        <td>go to github issues (only if github is preferred repository)</td>
      </tr>
    </tbody>
  </table>
</div>

<div class="col-md-6">
  <table class="table keyboard-shortcuts">
    <thead>
      <tr>
        <th></th>
        <th>POD</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td class="keys">
          <kbd>g</kbd> <kbd>a</kbd>
        </td>
        <td>Go to author</td>
      </tr>
      <tr>
        <td class="keys">
          <kbd>g</kbd> <kbd>c</kbd>
        </td>
        <td>Go to changes</td>
      </tr>
      <tr>
        <td class="keys">
          <kbd>g</kbd> <kbd>i</kbd>
        </td>
        <td>Go to issues</td>
      </tr>
      <tr>
        <td class="keys">
          <kbd>g</kbd> <kbd>d</kbd>
        </td>
        <td>Go to dist</td>
      </tr>
      <tr>
        <td class="keys">
          <kbd>g</kbd> <kbd>r</kbd>
        </td>
        <td>Go to repository/SCM</td>
      </tr>
      <tr>
        <td class="keys">
          <kbd>g</kbd> <kbd>s</kbd>
        </td>
        <td>Go to source</td>
      </tr>
      <tr>
        <td class="keys">
          <kbd>g</kbd> <kbd>b</kbd>
        </td>
        <td>Go to file browse</td>
      </tr>

    </tbody>
  </table>
</div>

<div class="col-md-12">
  <table class="table keyboard-shortcuts">
    <thead>
      <tr>
        <th></th>
        <th>Search terms</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td><em>module:</em> (e.g. <a href="https://metacpan.org/search?q=module%3APlugin">module:Plugin</a>)</td>
      </tr>
      <tr>
        <td><em>distribution:</em> (e.g. <a href="https://metacpan.org/search?q=distribution%3ADancer+auth">distribution:Dancer auth</a>)</td>
      </tr>
      <tr>
        <td><em>author:</em> (e.g. <a href="https://metacpan.org/search?q=author%3ASONGMU+Redis">author:SONGMU Redis</a>)</td>
      </tr>
      <tr>
        <td><em>version:</em> (e.g. <a href="https://metacpan.org/search?q=version%3A1.00">version:1.00</a>)</td>
      </tr>
    </tbody>
  </table>
</div>
              </div>
              <div class="modal-footer"></div>
            </div>
          </div>
        </div>
    </body>
</html>
